/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package day05.sinhvien;

/**
 *
 * @author Administrator
 */
public class SinhVien {
    private String ten;
    private String mssv;
    private int tuoi;
    private BangDiem bangDiem;
    
public SinhVien(String ten, String mssv, int tuoi, BangDiem bangDiem){
    this.ten      = ten;
    this.mssv     = mssv;
    this.tuoi     = tuoi;
    this.bangDiem = bangDiem;
}    
/*
 * toString
 */
@Override
public String toString(){    
 StringBuilder sb = new StringBuilder();
 sb.append(this.ten);
 sb.append(",");
 sb.append(this.mssv);
 sb.append(",");
 sb.append(this.tuoi);
 sb.append(",");
 sb.append(this.bangDiem);
 return sb.toString();

}
/*
 * tinh diem 
 */
public int tinhTongDiem(){
    return this.bangDiem.tinhTongDiem();
}
/*
 * Kiem tra dau rot
 */
public boolean ktDauRot(){
    return this.bangDiem.ktDauRot();
}

    public String getTen() {
        return ten;
    }



    
}
